package com.qf.hsr.demo01;

/**
 * @author q
 * @version V1.0
 * @date 2021/11/06
 **/
public class UserServiceProxy implements IUserService{

    private UserServiceImpl userService;

    public void setUserService(UserServiceImpl userService){
        this.userService = userService;
    }

    @Override
    public void save() {
        System.out.println("UserServiceProxy --> save中代理新增的功能~");
        userService.save();
    }

    @Override
    public int update() {
        System.out.println("UserServiceProxy --> update中代理新增的功能~");
        userService.update();
        return 0;
    }
}
